const path = require("path");
const {merge} = require("webpack-merge");
const baseConfig = require("./base");

const config = merge(baseConfig, {
  mode: "development",
  devtool: "source-map",
  watch: true,
  watchOptions: {
    aggregateTimeout: 300,//当第一个文件更改，会在重新构建前增加延迟。300ms
    poll: 1000,//通过传递 true 开启 polling，或者指定毫秒为单位进行轮
  },
});

module.exports = config;
